﻿@inject IJSRuntime _jsRuntime

<pre><code class="language-@language">@ChildContent</code></pre>
@code{
    [Parameter]
    public RenderFragment ChildContent { get; set; }
    [Parameter]
    public Language language { get; set; } = CodeBlock.Language.csharp;

    protected override async Task OnAfterRenderAsync(bool firstRender)
    {
        await _jsRuntime.InvokeVoidAsync("Prism.highlightAll");
    }
    public enum Language
    {
        csharp,html
    }
}
